const {jwtSecret,accessSecret} = require('../config/config.default')
const {sign} = require('../utils/jwt')
exports.generateAccessToken = async (user)=> {
    return await sign(user, accessSecret, { expiresIn: '60s' });
}

exports.generateRefreshToken = async (user)=> {
    return await sign(user, jwtSecret,{ expiresIn:'7d'});
}